/*
 * SelectionStatement.cpp
 *
 *  Created on: 06/05/2010
 *      Author: rodolfo
 */

#include "SelectionStatement.h"

SelectionStatement::SelectionStatement() :
        Statement ( selectionStm )
{

}
SelectionStatement::SelectionStatement ( StmType _kind ) :
        Statement ( _kind )
{

}

SelectionStatement::SelectionStatement ( Statement *command, StmType _kind ) :
        command ( command ), Statement ( _kind )
{
}

SelectionStatement::SelectionStatement ( Expression *condition, Statement *command, StmType _kind ) :
        condition ( condition ), command ( command ), Statement ( _kind )
{
}

SelectionStatement::SelectionStatement ( Expression *condition, StmType _kind ) :
        condition ( condition ), Statement ( _kind )
{
}

SelectionStatement::~SelectionStatement()
{
	if ( condition != 0 )
	    delete condition;
	if ( command != 0 )
		delete command;
}
